
const stepDefaultProp = {
  id: '',
  name: '',
  type: '',
  y: '',
  x: '',
  jobId: null,
  ico:'',
  attrs:{},
  config:""
}
  let Base64 = require('js-base64').Base64;
export default class Step {
  constructor(step = stepDefaultProp) {
    this.id = step.id.toString()
    this.name = step.name
    this.type = step.type
    this.y = step.y
    this.x = step.x
    this.attrs = step.attrs
    this.ico = step.ico
    this.config=step.config
  }
  setAttrs(attrs) {
    this.attrs = attrs;
    Base64.encode( this.attrs)
  }
  getAttrs() {
    return this.attrs;
  }
  getAttr(code) {
    return this.attrs[code]
  }

  setPos(x, y) {
    this.x = x
    this.y = y
  }
  
  getData(transformation) {
    return []
  }
}
